package com.dyna.foundation.domain.resp;

import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import java.time.LocalDateTime;
import java.util.Set;

@ApiModel(value = "管理后台 - 角色信息 Response VO")
@Data
public class SysRoleResp {

    @ApiModelProperty(value = "角色编号", required = true, example = "1")
    @ExcelProperty("角色序号")
    private Long id;

    @ApiModelProperty(value = "角色名称", required = true, example = "管理员")
    @ExcelProperty("角色名称")
    private String name;

    @ApiModelProperty(value = "角色标志", required = true, example = "admin")
    @NotBlank(message = "角色标志不能为空")
    @ExcelProperty("角色标志")
    private String code;

    @ApiModelProperty(value = "显示顺序", required = true, example = "1024")
    @ExcelProperty("角色排序")
    private Integer sort;

    @ApiModelProperty(value = "状态，参见 CommonStatusEnum 枚举类", required = true, example = "1")
    @ExcelProperty(value = "角色状态")
    private Integer status;

    @ApiModelProperty(value = "角色类型，参见 RoleTypeEnum 枚举类", required = true, example = "1")
    private Integer type;

    @ApiModelProperty(value = "备注", example = "我是一个角色")
    private String remark;

    @ApiModelProperty(value = "数据范围，参见 DataScopeEnum 枚举类", required = true, example = "1")
    @ExcelProperty(value = "数据范围")
    private Integer dataScope;

    @ApiModelProperty(value = "数据范围(指定部门数组)", example = "1")
    private Set<Long> dataScopeDeptIds;

    @ApiModelProperty(value = "创建时间", required = true, example = "时间戳格式")
    private LocalDateTime createTime;

}
